package com.zhuangjie.user.entity;

import com.baomidou.mybatisplus.annotation.*;
import io.swagger.annotations.ApiModel;
import io.swagger.annotations.ApiModelProperty;
import lombok.Getter;
import lombok.Setter;
import lombok.experimental.Accessors;

import java.io.Serializable;
import java.math.BigDecimal;
import java.time.LocalDateTime;

/**
 * <p>
 * 用户资产
 * </p>
 *
 * @author zhuangjie
 * @since 2024-04-04
 */
@Getter
@Setter
@Accessors(chain = true)
@TableName("user_asset")
@ApiModel(value = "UserAsset对象", description = "用户资产")
public class UserAsset implements Serializable {

    private static final long serialVersionUID = 1L;

    @ApiModelProperty("用户资产id")
    @TableId(value = "id", type = IdType.ASSIGN_ID)
    private Long id;

    @ApiModelProperty("用户id")
    @TableField("user_id")
    private Long userId;

    @ApiModelProperty("钱包金额")
    @TableField("wallet_amount")
    private BigDecimal walletAmount;

    @ApiModelProperty("积分")
    @TableField("points")
    private Integer points;

    @ApiModelProperty("创建时间")
    @TableField(value = "create_time", fill = FieldFill.INSERT)
    private LocalDateTime createTime;

    @ApiModelProperty("更新时间")
    @TableField(value = "update_time", fill = FieldFill.INSERT_UPDATE)
    private LocalDateTime updateTime;
}
